﻿@model ProductDetailsModel.GiftCardModel

@using SmartStore.Web.Models.Catalog;

@if (Model.IsGiftCard)
{
    <div class="pd-giftcard">
        <div class="form-group pd-giftcard-recipient-name">
            @Html.LabelFor(model => model.RecipientName, new { @class = "required", @for = Html.IdFor(x => x.RecipientName) })
            @Html.TextBoxFor(model => model.RecipientName, new { @class = "form-control" })
        </div>
        
        @if (Model.GiftCardType == SmartStore.Core.Domain.Catalog.GiftCardType.Virtual)
        {
            <div class="form-group pd-giftcard-recipient-email">
                @Html.LabelFor(model => model.RecipientEmail, new { @class = "required", @for = Html.IdFor(x => x.RecipientEmail) })
                @Html.TextBoxFor(model => model.RecipientEmail, new { @class = "form-control" })
            </div>
        }
        
        <div class="form-group pd-giftcard-sender-name">
            @Html.LabelFor(model => model.SenderName, new { @class = "required", @for = Html.IdFor(x => x.SenderName) })
            @Html.TextBoxFor(model => model.SenderName, new { @class = "form-control" })
        </div>
        
        @if (Model.GiftCardType == SmartStore.Core.Domain.Catalog.GiftCardType.Virtual)
        {
            <div class="form-group pd-giftcard-sender-email">
                @Html.LabelFor(model => model.SenderEmail, new { @class = "required", @for = Html.IdFor(x => x.SenderEmail) })
                @Html.TextBoxFor(model => model.SenderEmail, new { @class = "form-control" })
            </div>
        }
        
        <div class="form-group pd-giftcard-message">
            @Html.LabelFor(model => model.Message, new { @for = Html.IdFor(x => x.Message) })
            @Html.TextAreaFor(model => model.Message, new { @class = "form-control" })
        </div>
    </div>
}